<!-- 
 * Copyright (c) 2021-2025 申菱环境 All Rights Reserved
 * 项目名称：申菱物联平台
 * 模块名称：服务工单
 * 功能名称：工单首页
 * author : huzhiqi
 * date   : 2022/7/14 10:20
 -->
<template>
  <TablePage>
    <template #top>
      <div class="flex flex-row items-center justify-between pb-1">
        <div class="font-semibold text-2xl text-color-header">{{ t("routes.serviceWorkOrder") }}</div>
        <SelectableButtons
          v-show="workViewType === 'ADMIN'"
          v-model="currentRoleType"
          :data="roleTypeData"
          :last-has-mr="false"
        ></SelectableButtons>
        <!-- <a-radio-group v-model:value="currentRoleType" size="small" @change="handleChangeRole">
          <a-radio-button style="margin-right: 1rem; border-radius: 4px" :value="WorkRoleType.ADMIN">{{
            t("aiot.serviceOrder.manageView")
          }}</a-radio-button>
          <a-radio-button :value="WorkRoleType.OPERATION" style="border-radius: 4px; border-left-width: 1px">{{
            t("aiot.serviceOrder.operationView")
          }}</a-radio-button>
        </a-radio-group> -->
      </div>
      <!-- <SearchForm :title="t('routes.serviceApply')" :show-add-btn="false" @search="handleSearch" /> -->
      <a-tabs v-model:activeKey="activeKey" class="sl-tabs">
        <a-tab-pane v-for="item in tabArr" :key="item.key" style="height: 0px">
          <template #tab>
            <div class="flex flex-row items-center">
              <div>
                <a-badge
                  :count="applyNum ? applyNum[item.countKey] : 0"
                  show-zero
                  :number-style="item.numberStyle"
                ></a-badge>
              </div>
              <div class="text-lg"> {{ item.tabName || "-" }} </div>
            </div>
          </template>
        </a-tab-pane>
      </a-tabs>
      <SearchForm
        v-model:keyword="keyword"
        :keyword-search-data="searchModel"
        :add-btn-text="t('aiot.serviceOrder.createOrder')"
        :select-data="selectData"
        :add-btn-oper-type="OperPermissionType.MANAGE"
        :btn-route-name="routeName"
        @search="handleSearch"
        @add="handleAddFn"
      />
      <!-- <template #extraButtons>
          <a-button type="link" @click="refreshFn">
            <template #icon>
              <reload-outlined />
            </template>
            刷新
          </a-button>
        </template> -->
      <!-- </SearchForm> -->
    </template>
    <SlTable
      :columns="columns"
      row-key="workOrderId"
      :data-source="tableData"
      :loading="tableLoading"
      :pagination="pagination"
      :scroll="{ x: 'auto' }"
      :search-model="applySearchModel"
      :ignore-keys="['workRoleType', 'workSearchState', 'equipmentIds', 'projectIds']"
      @change="handleTableChange"
    >
      <template #bodyCell="{ column, record }: BodyCellOptions<WorkOrderInfo>">
        <a-space v-if="column.key === 'oper'">
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.DISPATCH, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="dispatchWorkOrderFn(record, BtnType.DISPATCH)"
            >{{ t("aiot.serviceOrder.dispatchWorkOrder") }}</PermissionBtn
          >
          <!-- 待派单运维可以取消 -->
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.REASSIGNMENT, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="dispatchWorkOrderFn(record, BtnType.REASSIGNMENT)"
            >{{ t("aiot.serviceOrder.changeDispatch") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.CANCEL, currentRoleType) || record.workOrderState === BtnType.DISPATCH"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleCancelFn(record)"
            >{{ t("common.cancel") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="record.evaluatesState === 'EVALUATED' && showBtnFn(record, BtnType.SEARCHEVALUATE, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleViewEvaluateFn(record)"
            >{{ t("aiot.serviceOrder.viewEvaluate") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="record.visitState === 'VISITING' && showBtnFn(record, BtnType.VISIT, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleRevisitFn(record)"
            >{{ t("aiot.serviceOrder.reVisit") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="record.visitState === 'VISITED' && showBtnFn(record, BtnType.SEARCHEVISIT, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="viewVisit(record)"
            >{{ t("aiot.serviceOrder.viewVisit") }}</PermissionBtn
          >
          <!-- 运营按钮 -->
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.REFUSE, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleOperatedWorkOrderFn(record, BtnType.REFUSE)"
            >{{ t("aiot.serviceOrder.rejectWorkOrders") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.RECEIVING, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleOperatedWorkOrderFn(record, BtnType.RECEIVING)"
            >{{ t("aiot.serviceOrder.receivingWorkOrders") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.TURNBACK, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleOperatedWorkOrderFn(record, BtnType.TURNBACK)"
            >{{ t("aiot.serviceOrder.reback") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.TURNDISPATCH, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="dispatchWorkOrderFn(record, BtnType.TURNDISPATCH)"
            >{{ t("aiot.serviceOrder.transWorkOrder") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.EXECUTE, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="handleOperatedWorkOrderFn(record, BtnType.EXECUTE)"
            >{{ t("aiot.serviceOrder.excute") }}</PermissionBtn
          >
          <!-- <PermissionBtn
            v-if="showBtnFn(record, BtnType.SIGNIN, currentRoleType)"
            :btn-props="{ type: 'link' }"
            @click="signInFn(record)"
            >{{ t("aiot.serviceOrder.signIn") }}</PermissionBtn
          > -->
          <!-- <PermissionBtn
            v-if="showBtnFn(record, BtnType.SIGNIN, currentRoleType)"
            :btn-props="{ type: 'link' }"
            @click="signInFn(record)"
            >签名</PermissionBtn
          > -->
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.CONSTRUCTION, currentRoleType)"
            :btn-props="{ type: 'link' }"
            @click="constructionWorkOrdersFn(record)"
            >{{ t("aiot.serviceOrder.constructionWorkOrders") }}</PermissionBtn
          >
          <PermissionBtn
            v-if="showBtnFn(record, BtnType.FINISH, currentRoleType)"
            :btn-props="{ type: 'link' }"
            :oper-type="OperPermissionType.MANAGE"
            :route-name="routeName"
            @click="finishWorkOrdersFn(record)"
            >{{ t("aiot.serviceOrder.finishWorkOrders") }}</PermissionBtn
          >
        </a-space>
        <div v-if="column.dataIndex === 'workOrderStateName'">
          <!-- <a-tag
            class="sl-tag !mr-2 !mb-2 text-center"
            style="width: 64px"
            :color="record.workOrderStateName === '超期' ? 'orange' : StateColor[record.workOrderState || '']"
          >
            {{ record.workOrderStateName }}
          </a-tag> -->
          <StateTag
            :color="record.workOrderStateName === '超期' ? '#f5b83c' : StateColorList[record.workOrderState || '']"
            :value="record.workOrderStateName"
          ></StateTag>
        </div>
        <a
          v-else-if="column.dataIndex === 'workOrderCode'"
          href="javascript:void(0)"
          @click="handleViewDetailFn(record)"
        >
          {{ record.workOrderCode }}
        </a>
        <div v-if="column.dataIndex === 'serviceType'">
          {{ getLabelByValueFromEnum(record.serviceType || "", ServiceType, "serviceType") }}
        </div>
        <div v-if="column.dataIndex === 'contactsPerson'">
          {{ record.contactsPerson + "(" + record.contactsPhone + ")" }}
        </div>
        <EllipsisText v-if="column.dataIndex === 'address'" :max-len="15" :text="record.address || ''" />
      </template>
    </SlTable>
    <CreateWorkOrderModal
      v-model:visible="createVisible"
      :inset-cls="getContainer === '#root' ? '1' : undefined"
      @create="createSuccessWorkOrderFn"
      @ok="handleCreatedFn"
    />
    <DispatchWorkOrder
      v-model:visible="dispatchModal"
      v-model:workOrderId="currentWorkOrder.workOrderId"
      v-model:current-btn-type="currentBtnType"
      :model="dispatchModel"
      :model-form-setting="dispatchModelFormSetting"
      @create="refreshFn"
    />
    <WorkOrderConstruction
      v-model:visible="constructionModal"
      v-model:workOrderId="currentWorkOrder.workOrderId"
      :model="constructionModel"
      :model-form-setting="constructionModelFormSetting"
      @create="refreshFn"
    />
    <CompleteWorkOrderModal
      v-model:visible="completeModal"
      v-model:workOrderId="currentWorkOrder.workOrderId"
      @create="refreshFn"
    />
    <SignInModal v-model:visible="signinModal" v-model:workOrderId="currentWorkOrder.workOrderId" @create="refreshFn" />
    <SelectUserModal
      v-model:visible="chooseUserVisible"
      v-model:projectId="currentWorkOrder.projectId"
      v-model:selectMode="selectUserMode"
      v-model:selectedUserIds="selectedUserIds"
      @ok="handleSelectedUser"
    />
    <WorkOrderDetails
      v-model:visible="detailVisible"
      v-model:worksOrderId="currentWorkOrder.workOrderId"
      v-model:workRoleType="currentRoleType"
      :route-name="routeName"
      @dispatch="dispatchWorkOrderFn"
      @cancel-fn="handleCancelFn"
      @evaluate-fn="handleViewEvaluateFn"
      @revisit-fn="handleRevisitFn"
      @view-visit="viewVisit"
      @work-order-fn="handleOperatedWorkOrderFn"
      @construct-fn="constructionWorkOrdersFn"
      @finish-fn="finishWorkOrdersFn"
      @success-fn="reloadTable"
    />
    <VisitModal :options="visitModalOptions" @ok="refreshFn" />
    <VisitDetail v-model:getDetailId="visitDetailOrderId" :get-container="getContainer" />
    <CommentDetail v-model:serviceOrderId="commentDetailOrderId" :get-container="getContainer" />
    <CancelApplyModal v-model:visible="cancelOrderVisible" :options="cancelModalOptions" @ok="refreshFn" />
  </TablePage>
</template>
<script lang="ts" setup>
import SignInModal from "./SignInModal.vue";
import WorkOrderConstruction from "./WorkOrderConstruction.vue";
import CompleteWorkOrderModal from "./CompleteWorkOrderModal.vue";
import WorkOrderDetails from "./WorkOrderDetails.vue";
import { ref, onMounted, watch, provide, computed } from "vue";
import { useI18n } from "/@/locales/useI18n";
import { getLabelByValueFromEnum } from "/@/utils/common";
import {
  Api,
  cancleWorkOrders,
  executeWorkOrders,
  receivingWorkOrders,
  refuseWorkOrders,
  cancelReceivingWorkOrders,
  summaryTodoWorkOrders,
} from "/@/api/aiot/serviceWorkOrder";
import { OperPermissionType } from "/@/api/aiot/role/models";
import { ServiceType } from "/@/api/aiot/serviceApply/models";
import type { SumItem, PartialWorkOrderInfo } from "/@/api/aiot/serviceWorkOrder/models";
import { WorkRoleType, BtnType, StateColorList } from "/@/api/aiot/serviceWorkOrder/models";
import type { WorkOrderInfo } from "/@/api/aiot/serviceWorkOrder/models";
import { useCURD } from "/@/hooks/useCURD";
import { OrderRule } from "/@/api/models";
import { useOrderModal } from "./useOrderModal";
import CreateWorkOrderModal from "./CreateWorkOrderModal.vue";
import InfoModal from "../../InfoModal";
import { message } from "ant-design-vue";
import { VisitModalOptions, CancelApplyModalOptions } from "/@/types/components";
import { enumToOptions } from "../../../utils/common";
import { WorkSourceAdmin, WorkSourceOpera, WorkType } from "../../../api/aiot/serviceWorkOrder/models";
import { LabelSelectType, SelectItem } from "../../../types/components";
import type { BodyCellOptions, SelectOptionItem } from "/@/types/antd";
import dayjs from "dayjs";
import { useUserStore } from "/@/stores/aiot/user";

const userStore = useUserStore();
const workViewType = computed(() => {
  return userStore.detail.userTenantInfoVo.workViewType;
});
const { t } = useI18n();
const props = defineProps<{
  projectId?: string;
  equipmentId?: string;
  routeName?: string;
}>();
const currentRoleType = ref<string>(WorkRoleType.ADMIN);
// 根据后端返回的workViewType 判断当前展示视图
if (workViewType.value !== "ADMIN") {
  currentRoleType.value = workViewType.value;
}
const getContainer = computed(() => {
  // "#home-content"
  return props.routeName ? "#root" : "#home-content";
});
const roleTypeData = ref<SelectOptionItem[]>([
  {
    value: WorkRoleType.ADMIN,
    label: "管理视图",
  },
  {
    value: WorkRoleType.OPERATION,
    label: "运维视图",
  },
]);
const {
  selectedUserIds,
  selectUserMode,
  handleSelectedUser,
  columns,
  dispatchModel,
  dispatchModelFormSetting,
  chooseUserVisible,
  tabArr,
  showBtnFn,
  constructionModel,
  constructionModelFormSetting,
} = useOrderModal();
watch(currentRoleType, (val) => {
  if (val === WorkRoleType.ADMIN) {
    selectData.value[0].options = enumToOptions(WorkSourceAdmin, "workSource");
    selectData.value[0].options?.unshift({ label: "全部", value: "" });
  } else if (val === WorkRoleType.OPERATION) {
    selectData.value[0].options = enumToOptions(WorkSourceOpera, "workSource");
    selectData.value[0].options?.unshift({ label: "全部", value: "" });
  }
});
const openChange = (v) => {};
const panelChange = (v) => {};
const selectData = ref<SelectItem[]>([
  {
    label: t("aiot.serviceOrder.workSource"),
    value: "",
    key: "workSource",
    props: { allowClear: false },
    options: enumToOptions(WorkSourceAdmin, "workSource"),
  },
  {
    label: t("aiot.serviceOrder.workOrderType"),
    value: "",
    key: "workType",
    props: { allowClear: false },
    options: enumToOptions(WorkType, "workType"),
  },
  {
    label: t("aiot.serviceOrder.expectedTime"),
    value: "",
    props: {
      allowClear: true,
      onOpenChange: openChange,
      onPanelChange: panelChange,
    },
    key: "expectedTime",
    selectType: LabelSelectType.rangePicker,
  },
]);

selectData.value[0].options?.unshift({ label: "全部", value: "" });
selectData.value[1].options?.unshift({ label: "全部", value: "" });
const {
  tableData,
  tableLoading,
  reloadTable,
  pagination,
  searchModel: applySearchModel,
} = useCURD<WorkOrderInfo>({
  getPageUrl: Api.pageWorkOrders,
  loadOnMounted: false,
});
const activeKey = ref<string>("ALL");
const commentDetailOrderId = ref<string>("");
const createVisible = ref<boolean>(false);
const detailVisible = ref<boolean>(false);
const signinModal = ref<boolean>(false);
const cancelOrderVisible = ref<boolean>(false);
const currentWorkOrder = ref<PartialWorkOrderInfo>({});
const keyword = ref<string>("");
const dispatchModal = ref<boolean>(false);
const constructionModal = ref<boolean>(false);
const completeModal = ref<boolean>(false);
const applyNum = ref<SumItem>({});
const cancelModalOptions = ref<CancelApplyModalOptions>();
const visitDetailOrderId = ref<string | null>(null);
const visitModalOptions = ref<VisitModalOptions>();
const currentBtnType = ref<string>("");
const searchModel = [{ key: "searchText", label: t("aiot.serviceOrderOperationMsg.searchText") }];

watch(activeKey, (val) => {
  let model = {
    workSearchState: val,
    searchText: keyword.value,
    projectIds: props.projectId ? [props.projectId] : [],
    equipmentIds: props.equipmentId ? [props.equipmentId] : [],
  };
  val === "ALL" ? (model.workSearchState = "") : ""; // reloadTable({ model: { workSearchState: val }, current: 1 });
  reloadTable({ model, current: 1 });
  searchApplyNum();
});
onMounted(async () => {
  reloadTable({
    model: {
      workRoleType: currentRoleType.value,
      projectIds: props.projectId ? [props.projectId] : [],
      equipmentIds: props.equipmentId ? [props.equipmentId] : [],
    },
    current: 1,
  });
  searchApplyNum();
});
// 刷新table以及数量
async function refreshFn() {
  searchApplyNum();
  reloadTable();
  detailVisible.value = false;
}
// 项目切换计划时间
function handleTableChange(pag: { pageSize: number; current: number }, filters: any, sorter: any) {
  if (sorter.field === "plannTime") {
    let obj = { sort: "plannTime", order: OrderRule.ASC };
    if (sorter.order === "ascend") {
      obj.order = OrderRule.ASC;
    } else if (sorter.order === "descend") {
      obj.order = OrderRule.DESC;
    } else {
      obj.order = OrderRule.ASC;
    }
    reloadTable(obj);
  }
}
// 切换
// 创建工单
function handleAddFn() {
  createVisible.value = true;
}
// 查看详情
function handleViewDetailFn(row) {
  currentWorkOrder.value = row;
  detailVisible.value = true;
}
// 查看回访
function viewVisit(record) {
  visitDetailOrderId.value = record.workOrderId;
  currentWorkOrder.value = record;
}
/**
 * 取消工单
 * @param record
 */
function handleCancelFn(record) {
  cancelOrderVisible.value = true;
  cancelModalOptions.value = {
    workOrderId: record.workOrderId,
  };
}
/***
 * 操作工单方法
 */
// 工单操作 取消 执行 接单 退回
async function handleOperatedWorkOrderFn(record, type) {
  switch (type) {
    case BtnType.CANCEL:
      InfoModal.confirm({
        content: t("aiot.serviceOrder.cancelMsg"),
        async onOk() {
          let req = await cancleWorkOrders({ workOrderId: record.workOrderId });
          if (req) {
            message.success(t("aiot.serviceOrderOperationMsg.cancelOk"));
            refreshFn();
          }
        },
      });
      break;
    case BtnType.EXECUTE:
      InfoModal.confirm({
        content: t("aiot.serviceOrder.executeMsg"),
        async onOk() {
          let req = await executeWorkOrders({ workOrderId: record.workOrderId });
          if (req) {
            req && message.success(t("aiot.serviceOrderOperationMsg.excuteOk"));
            refreshFn();
          }
        },
      });
      break;
    case BtnType.RECEIVING:
      InfoModal.confirm({
        content: t("aiot.serviceOrder.receiveMsg"),
        async onOk() {
          let req = await receivingWorkOrders({ workOrderId: record.workOrderId });
          if (req) {
            req && message.success(t("aiot.serviceOrderOperationMsg.receiveOk"));
            refreshFn();
          }
        },
      });
      break;
    case BtnType.REFUSE:
      InfoModal.confirm({
        content: t("aiot.serviceOrder.refuseMsg"),
        async onOk() {
          let req = await refuseWorkOrders({ workOrderId: record.workOrderId });
          if (req) {
            req && message.success("拒接成功");
            refreshFn();
          }
        },
      });
      break;
    case BtnType.TURNBACK:
      InfoModal.confirm({
        content: t("aiot.serviceApply.turnBackMsg"),
        async onOk() {
          let req = await cancelReceivingWorkOrders({ workOrderId: record.workOrderId });
          if (req) {
            message.success(t("aiot.serviceOrderOperationMsg.turnBackOk"));
            refreshFn();
          }
        },
      });
      break;
    default:
      break;
  }
}
// 创建工单成功
function createSuccessWorkOrderFn() {
  message.success(t("aiot.serviceOrderOperationMsg.createOrderMsg"));
  createVisible.value = false;
  reloadTable();
}
// 查看评价
function handleViewEvaluateFn(record) {
  // commentDetailOrderId.value = record.serviceOrderId;
  commentDetailOrderId.value = record.workOrderId;
  currentWorkOrder.value = record;
}
// 回访
function handleRevisitFn(record) {
  visitModalOptions.value = {
    workOrderId: record.workOrderId,
    workOrderVisitRecordType: "NORMAL",
  };
}
// 签到
function signInFn(record) {
  currentWorkOrder.value = record;
  signinModal.value = true;
}
function signature(record) {}
// 施工
function constructionWorkOrdersFn(record) {
  currentWorkOrder.value = record;
  constructionModal.value = true;
}
// 完工
function finishWorkOrdersFn(record) {
  currentWorkOrder.value = record;
  completeModal.value = true;
}
// 派单
// 转派 改派 派单
function dispatchWorkOrderFn(record, btnType) {
  currentBtnType.value = btnType;
  currentWorkOrder.value = record;
  if (dispatchModelFormSetting.value[0].props) {
    dispatchModelFormSetting.value[0].props.projectId = record.projectId;
  }
  if (dispatchModelFormSetting.value[1].props) {
    dispatchModelFormSetting.value[1].props.projectId = record.projectId;
  }
  dispatchModel.value.plannTime = dayjs().format(t("common.dateTimeFormatStr1"));
  dispatchModal.value = true;
}
// 查询工单数量
async function searchApplyNum() {
  let req = await summaryTodoWorkOrders({
    workRoleType: currentRoleType.value,
    projectIds: props.projectId ? [props.projectId] : [],
    equipmentIds: props.equipmentId ? [props.equipmentId] : [],
  });
  applyNum.value = req ? req : {};
}
watch(currentRoleType, () => {
  handleChangeRole();
});
// 切换视图
async function handleChangeRole() {
  searchApplyNum();
  reloadTable({
    model: {
      plannTimeStart: "",
      plannTimeEnd: "",
      workRoleType: currentRoleType.value,
      projectIds: props.projectId ? [props.projectId] : [],
      equipmentIds: props.equipmentId ? [props.equipmentId] : [],
    },
    current: 1,
  });
}
function handleSearch(model) {
  if (model?.expectedTime?.length > 0) {
    model.plannTimeStart = model.expectedTime[0];
    model.plannTimeEnd = model.expectedTime[1];
  } else {
    model.plannTimeStart = "";
    model.plannTimeEnd = "";
  }
  model.workSource === "ALL" ? (model.workSource = "") : "";
  model.workType === "ALL" ? (model.workType = "") : "";
  reloadTable({ model, current: 1 });
}

function handleCreatedFn() {
  createVisible.value = false;
  refreshFn();
}
function cancelFlag(record) {
  console.log("record=>", record);
  console.log(showBtnFn(record, BtnType.CANCEL, currentRoleType));
  return showBtnFn(record, BtnType.CANCEL, currentRoleType);
}
</script>
<!-- <style lang="less" scoped>
:deep(.ant-radio-button-wrapper-checked) {
  background: rgba(66, 133, 244, 0.1) !important;
}
:deep(.ant-radio-button-wrapper) {
  background: #e9ebee;
}
:deep(.ant-radio-button-wrapper:not(:first-child)::before) {
  width: 0px;
}
</style> -->
